home *** CD-ROM | disk | FTP | other *** search
/ Chip 2007 January, February, March & April / Chip-Cover-CD-2007-02.iso / Pakiet bezpieczenstwa / mini Pentoo LiveCD 2006.1 / mpentoo-2006.1.iso / livecd.squashfs / usr / lib / mozilla-firefox / idl / nsISOAPBlock.idl < prev    next >
Text File  |  2006-05-08  |  5KB  |  130 lines

  1. /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
  2. /* ***** BEGIN LICENSE BLOCK *****
  3.  * Version: MPL 1.1/GPL 2.0/LGPL 2.1
  4.  *
  5.  * The contents of this file are subject to the Mozilla Public License Version
  6.  * 1.1 (the "License"); you may not use this file except in compliance with
  7.  * the License. You may obtain a copy of the License at
  8.  * http://www.mozilla.org/MPL/
  9.  *
  10.  * Software distributed under the License is distributed on an "AS IS" basis,
  11.  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
  12.  * for the specific language governing rights and limitations under the
  13.  * License.
  14.  *
  15.  * The Original Code is mozilla.org code.
  16.  *
  17.  * The Initial Developer of the Original Code is
  18.  * Netscape Communications Corporation.
  19.  * Portions created by the Initial Developer are Copyright (C) 2001
  20.  * the Initial Developer. All Rights Reserved.
  21.  *
  22.  * Contributor(s):
  23.  *
  24.  * Alternatively, the contents of this file may be used under the terms of
  25.  * either the GNU General Public License Version 2 or later (the "GPL"), or
  26.  * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
  27.  * in which case the provisions of the GPL or the LGPL are applicable instead
  28.  * of those above. If you wish to allow use of your version of this file only
  29.  * under the terms of either the GPL or the LGPL, and not to allow others to
  30.  * use your version of this file under the terms of the MPL, indicate your
  31.  * decision by deleting the provisions above and replace them with the notice
  32.  * and other provisions required by the GPL or the LGPL. If you do not delete
  33.  * the provisions above, a recipient may use your version of this file under
  34.  * the terms of any one of the MPL, the GPL or the LGPL.
  35.  *
  36.  * ***** END LICENSE BLOCK ***** */
  37.  
  38. #include "nsISupports.idl"
  39.  
  40. interface nsIDOMElement;
  41. interface nsIVariant;
  42. interface nsISOAPEncoding;
  43. interface nsISchemaType;
  44. interface nsISOAPAttachments;
  45.  
  46. /**
  47.  * This interface encapsulates an arbitrary block to be used
  48.  * by the soap serialization or protocol.  It presents the
  49.  * namespaceURI, name, encoding, schemaType, and value of the
  50.  * block.  There are two different ways this may be used:
  51.  * <p>1.  When created by a user for serialization, a value is set
  52.  * which is then used to encode the message.  In this case, the
  53.  * user sets the value (or element in the case of a literal
  54.  * block) which is then encoded (unless it is the element) 
  55.  * and incorporated into the document as it is encoded.
  56.  * <p>2.  When requested by the user from a message that is to
  57.  * be decoded.  In this case, an element is set on the block
  58.  * which is automatically decoded whenever the value attribute is
  59.  * accessed (possibly after the user sets the encoding or schemaType,
  60.  * or for literal blocks, the user just accesses the element and
  61.  * no decoding is performed.  For SOAP which attachments, hidden 
  62.  * attachments may also be associated from the message to the block 
  63.  * so that later decoding which relies on the attachments is possible.
  64.  */
  65.  
  66. [scriptable, uuid(843afaa8-1dd2-11b2-8b0d-9b5d16fe64ea)]
  67. interface nsISOAPBlock : nsISupports {
  68.   /**
  69.    *  Initialize the block for additional decoding information.
  70.    *
  71.    * @param aAttachments Attachments in case this refers to them.
  72.    *
  73.    * @param aVersion SOAP version for decoding special header attributes.
  74.    */
  75.   void init(in nsISOAPAttachments aAttachments,
  76.             in unsigned short aVersion);
  77.  
  78.   /**
  79.    *  The namespace URI of the block.  Ignored if name is null.
  80.    *  If this is modified, element is set to null and all 
  81.    *  attributes computed from element revert to previous
  82.    *  uncomputed values.  If element is set, this becomes computed.
  83.    */
  84.   attribute AString namespaceURI;
  85.  
  86.   /**
  87.    * The name of the block. If the block is left unnamed, it
  88.    * will be encoded using the element types defined in the SOAP-ENC
  89.    * schema. For example, <code><SOAP-ENC:int>45</SOAP-ENC:int>
  90.    * </code>.  If this is modified, element is set to null and all 
  91.    * attributes computed from element revert to previous uncomputed
  92.    * values.  If element is set, this becomes computed.
  93.    */
  94.   attribute AString name;
  95.  
  96.   /**
  97.    * The encoding that was / will be applied to the
  98.    * block.  If this is blank and element is non-null,
  99.    * it becomes impossible to decode the block when
  100.    * the value is requested.
  101.    */
  102.   attribute nsISOAPEncoding encoding;
  103.  
  104.   /**
  105.    * The schema type used to encode or decode the
  106.    *   block.  If this is null, then the default
  107.    *   encoder or decoder may 
  108.    */
  109.   attribute nsISchemaType schemaType;
  110.  
  111.   /**
  112.    *  The element which is the encoded value of this block.
  113.    *  If this is set, value, namespaceURI, and name becomes a 
  114.    *  computed attributes which are produced by decoding this 
  115.    *  element.
  116.    */
  117.   attribute nsIDOMElement element;
  118.  
  119.   /**
  120.    *  The native value which is the decoded value of 
  121.    *  this block.  If this is modified, element is set
  122.    *  to null and all attributes computed from element 
  123.    *  revert to previous uncomputed values.  If element 
  124.    *  is set, this becomes computed, relying on the 
  125.    *  value of encoding and schemaType each time it is 
  126.    *  computed.
  127.    */
  128.   attribute nsIVariant value;
  129. };
  130.